<%--
  Created by IntelliJ IDEA.
  User: lenovo
  Date: 2025/5/31
  Time: 13:05
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<html>
<head>
    <title>我的订单</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    <link type="text/css" rel="stylesheet" href="css/base.css">
    <link type="text/css" rel="stylesheet" href="css/common.css">
    <link type="text/css" rel="stylesheet" href="css/index.css">
    <script type="text/javascript" src="js/index.js" defer></script>
</head>
<body>

<jsp:include page="header.jsp">
    <jsp:param name="flag" value="3"/>
</jsp:include>

<div class="container order-list">
    <div class="tabs">
        <div class="tab "><a href="/order_list.jsp">全部</a></div>
        <div class="tab" data-type="buy"><a href="/orderBuy_list.jsp">我买的</a></div>
        <div class="tab tabs-active" data-type="sell"><a href="/orderSell_list.jsp"  class="tab-active">我卖的</a></div>
    </div>
    <div class="orders-list" id="ordersList">
        <c:forEach items="${orderListSell}" var="order">
            <div class="order-card">
                <div class="order-code">订单编号：${order.code}</div>
                <div class="order-info">
                    <img class="product-img" src="${pageContext.request.contextPath }${order.goods.image1}" alt="商品名称">
                    <div class="product-name">${order.goods.name}</div>
                    <div class="product-items">共 ${order.amount} 件商品</div>
                    <div class="product-total">总计 ￥${order.buy_price}</div>
                </div>
            </div>
        </c:forEach>
    </div>
</div>

</body>
</html>
